<?php
if(!$_SESSION['user_id'])
	session_start();
if($_COOKIE['email'] && !$_SESSION['user_id']){
	require_once "pg/login-cookie.php";
	LoginCookie($_COOKIE['email'], $_COOKIE['pass']);
}
if(!$_SESSION['user_id']){
	$title = "OseeYou chào bạn";
	//header
	include "pg/html-header.php";
	include "pg/html-menu.php";
	echo '<div id="content_full">';
	echo '<div id = "content_left">';
		include "pg/index-left.php";
		
	echo '</div>';
	
	echo '<div id = "content_right">';
		echo '<div class = "singup">';
			if(!$_GET){		
				include "pg/login-ct.php";
			}	
			else{
				switch($_GET['pg']){			
				case 'singup': include "pg/singup.php";
				break;			
				}				
			}	
		echo '</div>';
	echo '</div>';
	echo '</div>';//end #content_full	
}
else if($_SESSION['user_id']){
	$title = "OseeYou chào ".$_SESSION['full_name'];
	//header
	include "pg/html-header.php";	
	include "pg/html-menu.php";
	echo '<div id = "container">';
		echo '<div id = "content">';
			include "pg/index-content.php";
		echo '</div>';	
	echo '</div>';	
	echo '<div id = "sideLeft">';
		include "pg/index-sideLeft.php";
	echo '</div>';
	echo '<div id = "sideRight">';
		include "pg/index-sideRight.php";
	echo '</div>';
}			
include "pg/html-footer.php";
?>
